using System;
using System.Collections.Generic;
using System.Text;

namespace Sixeyed.CacheAdapter.NCacheExpressProvider
{
    /// <summary>
    /// Represents an exception using NCache Express 
    /// </summary>
    public class NCacheExpressProviderException : Exception
    {
        /// <summary>
        /// Default constructor
        /// </summary>
        public NCacheExpressProviderException () { }

        /// <summary>
        /// Constructor with known state
        /// </summary>
        /// <param name="messageFormat">Message format</param>
        /// <param name="args">Message arguments</param>
        public NCacheExpressProviderException(string messageFormat, params object[] args) : base(string.Format(messageFormat, args)) { }

        /// <summary>
        /// Constructor with known state
        /// </summary>
        /// <param name="innerException">Inner exception</param>
        public NCacheExpressProviderException(Exception innerException) : base(string.Empty, innerException) { }

        /// <summary>
        /// Constructor with known state
        /// </summary>
        /// <param name="innerException">Inner exception</param>
        /// <param name="messageFormat">Message format</param>
        /// <param name="args">Message arguments</param>
        public NCacheExpressProviderException(Exception innerException, string messageFormat, params object[] args) : base(string.Format(messageFormat, args), innerException) { }
    }
}
